{% extends 'blog/base.html' %}
{% block contentBlock %}
    <div class="container">
        <article id="post-2" class="js-gallery post-2 page type-page status-publish has-post-thumbnail hentry">
            <style>
                .meta {
                    display: none;
                }

                #NextPrevPosts {
                    margin: 0;
                    visibility: hidden;
                }
            </style>
            <section class="post_content">
                <header class="post_header">
                    <h1 class="post_title">街坊留言</h1>
                </header>

                <div class="meta split split--responsive cf" style="display: block;">
                </div>
            </section>
        </article>
    </div>
    <svg id="upTriangleColor" width="100%" height="40" viewBox="0 0 100 102" preserveAspectRatio="none">
        <path d="M0 0 L50 100 L100 0 Z"></path>
    </svg>
    <div id="panel">
        <div class="comment-area">
            <section class="comments">
                <div class="comments-main">
                    <div id="comments-list-title"><span>{{ gustbook_list|length }}</span> 条留言 </div>
                    <div id="loading-comments">
                        <div class="host">
                            <div class="loading loading-0"></div>
                            <div class="loading loading-1"></div>
                            <div class="loading loading-2"></div>
                        </div>
                    </div>
                    <ul class="commentwrap">
                        {% load pagination_tags %}
                        {% autopaginate gustbook_list 10 %}
                        {% for gustbook in gustbook_list %}
                            {% if not forloop|divisibleby:2 %}
                            <li class="comment even thread-even depth-1" id="li-comment-">
                            <div id="comment-936" class="comment_body contents">
                                <div class="profile">
                                    <a href=""><img src="../../static/blog/images/d9885b7dc7a78f9cadfb81be7512d630.png" class="gravatar" alt="{{ gustbook.name }}"></a>
                                </div>
                                <div class="main shadow">
                                    <div class="commentinfo">
                                        <section class="commeta">
                                            <div class="shang">
                                                <h4 class="author"><a href="" target="_blank"><img src="../../static/blog/images/d9885b7dc7a78f9cadfb81be7512d630.png" class="gravatarsmall" alt="{{ gustbook.name }}">{{ gustbook.name }}</a></h4>
                                            </div>
                                        </section>
                                    </div>
                                    <div class="body">
                                        <p>{{ gustbook.text }}</p>
                                    </div>
                                    <div class="xia info">
                                        <span><time datetime="{{ gustbook.pub_date }}">{{ gustbook.pub_date }}</time></span>
                                        <span><a rel='nofollow' class='comment-reply-link' href='javascript:;' onclick='return addComment.moveForm( "comment-936", "936", "respond", "2" )' aria-label='回复给{{ gustbook.name }}'>回复</a></span>
                                    </div>
                                </div>
                            </div>
                        </li>
                            {% else %}
                            <li class="comment odd alt thread-odd thread-alt depth-1" id="li-comment-">
                            <div id="comment-949" class="comment_body contents">
                                <div class="profile">
                                    <a href=""><img src="../../static/blog/images/573594c6f0bb6559381e5acf27845208.jpg" class="gravatar" alt="{{ gustbook.name }}"></a>
                                </div>
                                <div class="main shadow">
                                    <div class="commentinfo">
                                        <section class="commeta">
                                            <div class="shang">
                                                <h4 class="author"><a href="" target="_blank"><img src="../../static/blog/images/573594c6f0bb6559381e5acf27845208.jpg" class="gravatarsmall" alt="{{ gustbook.name }}">{{ gustbook.name }}</a></h4>
                                            </div>
                                        </section>
                                    </div>
                                    <div class="body">
                                        <p>{{ gustbook.text }}</p>
                                    </div>
                                    <div class="xia info">
                                        <span><time datetime="{{ gustbook.pub_date|date:'Y-m-d' }}">{{ gustbook.pub_date }}</time></span>
                                        <span><a rel='nofollow' class='comment-reply-link' href='javascript:;' onclick='return addComment.moveForm( "comment-949", "949", "respond", "2" )' aria-label='{{ gustbook.name }}'>回复</a></span>
                                    </div>
                                </div>
                            </div>
                        </li>
                            {% endif %}
                        {% endfor %}
                        {% paginate %}
                    </ul>
                    <div id="respond" class="comment-respond">
                        <h6 id="replytitle" class="comment-reply-title"><a rel="nofollow" id="cancel-comment-reply-link" href="" style="display:none;">取消</a></h6>
                        <form action="{% url 'gust:get_gustbook' %}" method="post" id="commentform" class="clearfix">
                            {% csrf_token %}
                            <div class="clearfix"></div>
                            <div class="author-info">
                                {{ form.name }}
                                {{ form.name.errors }}
                                {{ form.email }}
                                {{ form.email.errors }}
                                {{ form.url }}
                                {{ form.url.errors }}
                            </div>
                            <div class="clearfix"></div>
                            <input type='hidden' name='comment_post_ID' value='2' id='comment_post_ID' />
                            <input type='hidden' name='comment_parent' id='comment_parent' value='0' />
                            <p style="display: none;"><input type="hidden" id="akismet_comment_nonce" name="akismet_comment_nonce" value="44ac0661b8" /></p>
                            <p style="display: none;"><input type="hidden" id="ak_js" name="ak_js" value="105" /></p>
                            <div class="comment-form-info">
                                <div class="real-time-gravatar"> <img id="real-time-gravatar" src="../../static/blog/images/d41d8cd98f00b204e9800998ecf8427e.png" alt="gravatar头像" />
                                </div>
                                <p class="input-row">
                                    <i class="row-icon"></i>
                                    {{ form.text }}
                                    {{ form.text.errors }}
                                    <input type="submit" name="submit" class="button" id="submit" tabindex="5" value="发送" />
                                </p>
                            </div>
                        </form>
                    </div>
                </div>
            </section>
        </div>
    </div>
    <svg id="dwTriangleColor" width="100%" height="40" viewBox="0 0 100 102" preserveAspectRatio="none">
        <path d="M0 0 L50 100 L100 0 Z"></path>
    </svg>
    <div class="wrapper">
			</div>
{% endblock %}
